package com.devin.service.impl;

import com.devin.model.entity.BiliVideo;
import com.devin.repository.BilibiliRepository;
import com.devin.repository.MovieRepository;
import com.devin.repository.base.BaseRepository;
import com.devin.service.BilibiliService;
import com.devin.service.base.AbstractCrudService;
import org.springframework.stereotype.Service;

/**
 *  
 *  @author devin
 *  @date 2020-04-14 19:15
 *  @version 1.0.2
*/

@Service
public class BilibiliServiceImpl extends AbstractCrudService<BiliVideo, Long> implements BilibiliService {


    private final BilibiliRepository bilibiliRepository;

    protected BilibiliServiceImpl(BaseRepository<BiliVideo, Long> repository, BilibiliRepository bilibiliRepository) {
        super(repository);
        this.bilibiliRepository = bilibiliRepository;
    }

    @Override
    public BiliVideo findByLink(String link){
        return this.bilibiliRepository.findByLink(link);
    }
}
